//
//  DisplayViewTree.h
//  YuiKe
//
//  Created by yuike6 yuike6 on 11-9-7.
//  Copyright 2011年 yuike. All rights reserved.
//

#import <Foundation/Foundation.h>



@interface DisplayViewTree : NSObject
/*
 DISPLAY A RECURSIVE VIEW HIERARCHY TREE
 */
// Recursively travel down the view tree, increasing the indentation level for children
+ (void) dumpView: (UIView *) aView atIndent: (int) indent into:(NSMutableString *) outstring deep:(int)deep;
// Start the tree recursion at level 0 with the root view
+ (NSString *) dumpViews: (UIView *) aView deep:(int)deep;
// Show the tree
+ (void) displayViews: (UIView*) view deep:(int)deep;
+ (void) displayViews: (UIView*) view;

// 从这棵树的根开始打印，打印 它的 深度搜索路径。
// 比如   displayViewsPx: button
/**
 [ 0] UIWindow -- (0, 0, 768, 1024)
 --[ 1] UIView -- (0, 0, 768, 1024)
 ----[ 2] UIView -- (0, 0, 768, 1024)
 ----[ 2] UIView -- (0, 0, 768, 1024)
 ----[ 2] UIView -- (0, 0, 1024, 768)
 ------[ 3] ContentViewPanl -- (0, 0, 768, 1024)
 ------[ 3] UIView -- (0, 0, 1024, 768)
 --------[ 4] ProductHeadView -- (0, 0, 768, 50)
 --------[ 4] UIScrollView -- (0, 50, 768, 974)
 --------[ 4] UIView -- (0, 0, 1024, 768)
 ----------[ 5] ProductImagesView -- (0, 0, 768, 1024)
 ------------[ 6] UIScrollView -- (-60, 0, 888, 1024)
 ------------[ 6] MyPageControl -- (0, 988, 768, 36)
 ------------[ 6] UIButton -- (736, 992, 32, 32)
 ----------[ 5] MyNaviBar -- (0, 0, 768, 44)
 **/
+ (void) displayViewsPx: (UIView*) view;
@end

